﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace SuiYuan.Demo.Pages
{
    /// <summary>
    /// TabControlPage.xaml 的交互逻辑
    /// </summary>
    public partial class TabControlPage : UserControl
    {
        public TabControlPage()
        {
            InitializeComponent();
            InitTabs();
        }


        /// <summary>
        /// 初始化内容中的TabControl
        /// </summary>
        private void InitTabs()
        {
            DefaultTabs.AddItem("页面1", new Page1());
            DefaultTabs.AddItem("页面2", new Page2());
            DefaultTabs.AddItem("页面3", new Page3());
            DefaultTabs.AddItem("页面4", new Page4());

            DefaultTabsWithClose.AddItem("页面1", new Page1());
            DefaultTabsWithClose.AddItem("页面2", new Page2());
            DefaultTabsWithClose.AddItem("页面3", new Page3());
            DefaultTabsWithClose.AddItem("页面4", new Page4());

            SimpleTabs.AddItem("页面1", new Page1());
            SimpleTabs.AddItem("页面2", new Page2());
            SimpleTabs.AddItem("页面3", new Page3());
            SimpleTabs.AddItem("页面4", new Page4());

            SimpleTabsWithClose.AddItem("页面1", new Page1());
            SimpleTabsWithClose.AddItem("页面2", new Page2());
            SimpleTabsWithClose.AddItem("页面3", new Page3());
            SimpleTabsWithClose.AddItem("页面4", new Page4());

            CardTabs.AddItem("页面1", new Page1());
            CardTabs.AddItem("页面2", new Page2());
            CardTabs.AddItem("页面3", new Page3());
            CardTabs.AddItem("页面4", new Page4());

            CardTabsWithClose.AddItem("页面1", new Page1());
            CardTabsWithClose.AddItem("页面2", new Page2());
            CardTabsWithClose.AddItem("页面3", new Page3());
            CardTabsWithClose.AddItem("页面4", new Page4());
        }
    }
}
